<template>
  <div>
    <el-form-item label="噪声防治措施">
      <el-select v-model="value.noiseMethodStatus" :disabled="disabled" placeholder="请选择" class="input" @change="handleChange">
        <el-option
          v-for="dict in dict.type.env_system_has_or_not"
          :key="dict.value"
          :label="dict.label"
          :value="dict.value"
        />
      </el-select>
    </el-form-item>
    <template v-if="value.noiseMethodStatus === '有'">
      <el-form-item label="措施说明">
        <el-input v-model="value.noiseMethodRemark" :disabled="disabled" type="textarea" class="input" placeholder="请输入内容" @change="handleChange" />
      </el-form-item>
    </template>
  </div>
</template>
<script>
export default {
  name: 'Noise',
  dicts: ['env_system_has_or_not'],
  props: {
    disabled: Boolean,
    value: {
      type: Object,
      default: () => ({})
    }
  },
  data() {
    return {

    }
  },
  methods: {
    handleChange() {
      this.$emit('input', this.value)
      this.$emit('change', this.value)
    }
  }
}
</script>
